Changing Cursor on Image Hover using JavaScript
The event captured in this case is “onMouseOver” and “onMouseOut” .
The cursor can be changed with the following script:
onmouseover=”this.style.cursor = ‘hand’;”
onmouseout=”this.style.cursor = ‘auto’;”
Example:
imageLinkForDemo.Attributes.Add(“onMouseOver”, “this.style.cursor=’hand'”);
Now whenever a user hovers on the image, the mouse cursor changes to a hand image.
is it possible to keep my own image to the cursor say
onmouseover=”this.style.curso’vasu.jpg'”. i want this requorement if u know plz reply to my mail call2kancherla@gmail.com
srinivas said this on September 19, 2008 at 11:30 am |
@Srinivas : You can use the below code on page head..
To read more about this goto http://www.javascriptkit.com/script/script2/customcursor.shtml
Neha Sinha said this on September 23, 2008 at 12:34 pm |
Thanks it helped me
MJS said this on September 9, 2009 at 3:06 pm |
Doesn’t work in FF.
FS said this on October 20, 2010 at 9:20 pm |
Great to meet you and, wonderful Post site, of which consist of very good information.
..bless you for the great post
Jessica said this on August 18, 2012 at 12:04 am |